<?php
error_reporting(0);
require_once 'model/api/Taoapi.php';
require_once 'model/function.php';
require_once 'config.php';

$Taoapi_Config = Taoapi_Config::Init();
$Taoapi_Config->setCharset('UTF-8');	$Taoapi_Config->setAppKey($app);
$Taoapi = new Taoapi;
$Taoapi->method = 'taobao.user.get';
$Taoapi->fields = 'user_id';
$Taoapi->nick = $_GET['nick'];
$result = $Taoapi->Send('get','xml')->getArrayData();
$userinfo = $result['user'];

$con=file_get("http://rate.taobao.com/detail_rate.htm?userNumId=".$userinfo['user_id']."&auctionNumId=".$_GET['iid']."&showContent=1&currentPage=1");
preg_match_all("/\"rateContent\":\"(.*)\".*\"displayUserNick\":\"(.*)\"/Uis",$con,$arr);
?>
<div class="comment_box">
<div class="title_box">
<span class="title">卖家评论</span>
</div>
<div class="comment_list" id="comment_area">


<?php for($i=0;$i<count($arr[1]);$i++){ ?>
<Li>
<span class="content">评论内容：<?php echo iconv("gb2312","utf-8",$arr[1][$i]);?></span>
<span class="maijia">买家：<?php echo iconv("gb2312","utf-8",$arr[2][$i]);?></span>
</Li>
<?php }?>
<li><img src="/templates/<?php echo $moban;?>/style/more_comments.gif" onclick="clickurl('<?php echo $_GET['url'];?>');" style="cursor:pointer"/></li>
</div>
</div>